package com.bgs.eat.text;

import com.bgs.eat.config.CommonResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

/**
 * @ClassName TestController
 * @Description TODO
 * @Author lzy
 * @Date 2022/10/9 13:50
 **/
@RestController
@CrossOrigin
@RequestMapping("/test")
public class TestController {

    @Autowired
    TestMapper testMapper;

    @GetMapping("/testPublic")
    public CommonResult testPublic() {
        List<TestEntity> objects = testMapper.testPublic();
        return CommonResult.ok(objects);
    }

}
